<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%@ page import="org.acegisecurity.context.SecurityContextHolder" %>
<%@ page import="org.acegisecurity.userdetails.UserDetails" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- 名字空间 文档格式 -->
<html xmlns="http://www.w3.org/1999/xhtml" lang="utf-8"> 
<head>
<!-- 定义语言编码 -->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<!-- 允许搜索机器人搜索站内所有链接。如果你想某些页面不被搜索，推荐采用robots.txt方法 -->
<!-- <meta content="all" name="robots" /> -->
<!-- 设置站点作者信息 -->
<meta name="author" content="feigme@gmail.com, Feigme H.Guo" /> 
<!-- 收藏夹小图标 -->
<link rel="icon" href="../images/favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="../images/favicon.ico" type="image/x-icon" />
<!-- 设置站点版权信息 -->
<meta name="Copyright" content="fms" />
<!-- 站点的简要介绍 -->
<meta name="description" content="个人理财系统，个人CRM" />
<!-- 站点的关键词 -->
<meta content="feigme,fms" name="keywords" />
<!-- 引入css样式文件 -->
<link rel="StyleSheet" href="../css/base.css" type="text/css" media="screen" />
<link rel="StyleSheet" href="../css/main.css" type="text/css" media="screen" />
<script type="text/javascript" src="../js/prototype.js"></script>
<title>Feigme</title>
</head>
<body>
<div id="wrapper"><!--wrapper-->
	<div id="header">
		<div id="userhelp">
			<ul>
			<li><a href="<c:url value="#"/>"><fmt:message key="html.help"></fmt:message></a></li>
			<li id="menuDiv"></li>
			<li>
				<%
				Object obj = SecurityContextHolder.getContext().getAuthentication().getPrincipal();

				if(obj!=null && obj instanceof UserDetails) {
					String username = ((UserDetails)obj).getUsername();
				%>
				<a href="<c:url value="../j_acegi_logout"/>"><fmt:message key="html.loginout"></fmt:message></a>
			</li>
			<li id="menuDiv"></li>
			<li id="displayUsername">
				<%
				out.println(username);
				}else{
 				%>
				<a href="<c:url value="/identity/login.jsp"/>"><fmt:message key="html.login.menu"></fmt:message></a>
				<%} %>
			</li>
			</ul>
		</div>
		
		<div id="banner">
			<div id="globalSearch">
				<form action="<c:url value="/search/s.action"/>" method="post">
				<input type="text" name="keyWords"/>
				<input type="submit" value="<fmt:message key="html.search"/>"/>
				</form>
			</div>
		</div>
	</div>
	<div id="outer"><!--outer-->
	<div id="clearheader"></div>